1# SPDX-License-Identifier: GPL-2.0+
2# Copyright (c) 2016 Google, Inc
3
4import pytest
5import utils
6
7@pytest.mark.boardspec('sandbox_spl')
8@pytest.mark.buildconfigspec('spl_of_platdata')
9def test_spl_devicetree(ubman):
10    """Test content of spl device-tree"""
11    dtb = ubman.config.build_dir + '/spl/u-boot-spl.dtb'
12    fdtgrep = ubman.config.build_dir + '/tools/fdtgrep'
13    output = utils.run_and_log(ubman, [fdtgrep, '-l', dtb])
14
15    assert "bootph-all" not in output
16    assert "bootph-some-ram" not in output
17    assert "bootph-pre-ram" not in output
18    assert "bootph-pre-sram" not in output
19
20    assert "spl-test5" not in output
21    assert "spl-test6" not in output
22    assert "spl-test7" in output
23