|
| 1 | +# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*- |
| 2 | +# vi: set ft=python sts=4 ts=4 sw=4 et: |
| 3 | +# |
| 4 | +# Copyright 2021 The NiPreps Developers <[email protected]> |
| 5 | +# |
| 6 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 7 | +# you may not use this file except in compliance with the License. |
| 8 | +# You may obtain a copy of the License at |
| 9 | +# |
| 10 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | +# |
| 12 | +# Unless required by applicable law or agreed to in writing, software |
| 13 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 14 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 15 | +# See the License for the specific language governing permissions and |
| 16 | +# limitations under the License. |
| 17 | +# |
| 18 | +# We support and encourage derived works from this project, please read |
| 19 | +# about our expectations at |
| 20 | +# |
| 21 | +# https://www.nipreps.org/community/licensing/ |
| 22 | +# |
| 23 | +from ..norm import SpatialNormalization |
| 24 | + |
| 25 | + |
| 26 | +def test_get_settings(): |
| 27 | + norm = SpatialNormalization(moving='T1w', flavor='fast') |
| 28 | + settings = norm._get_settings() |
| 29 | + assert len(settings) == 1 |
| 30 | + assert settings[0].split('/')[-1] == 't1w-mni_registration_fast_000.json' |
| 31 | + |
| 32 | + norm = SpatialNormalization(moving='T1w', flavor='testing') |
| 33 | + settings = norm._get_settings() |
| 34 | + assert len(settings) == 3 |
0 commit comments