aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/synth/comp04/tb_comp06.vhdl
blob: 8320e32810ae2843980cea8187e557d42963ce25 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
entity tb_comp06 is
end tb_comp06;

library ieee;
use ieee.std_logic_1164.all;

architecture behav of tb_comp06 is
  signal v : std_logic_vector (7 downto 0);
  signal r : std_logic_vector (7 downto 0);
begin
  comp06_1: entity work.comp06
    port map (
      v => v,
      r => r);

  process
  begin
    v <= x"0f";
    wait for 1 ns;
    assert r = x"0c" severity failure;

    v <= x"f0";
    wait for 1 ns;
    assert r = x"70" severity failure;

    wait;
  end process;
end behav;