#!/bin/sh
#
# Test results last captured at "Fri Nov 14 12:42:49 PST 2003"
#
# This is an IBIS icm test program
#
# It is a self-contained package of all of the 
# files and data required to run an icm parser test.
#
# Usage:  ./test_157  <arg>
#
# <nothing>               = Run the test silently in GNU check mode
# "Brief"                 = Run the test.
#                           If there is no error, produce a one line summary
#                           Otherwise, produce a full test report.
# "Full"                  = Run the test and always produce a full test report
# "Capture"               = Capture test results and REWRITE the test program
# "Extract"               = Extract the .icm and .out files
#

Test=`basename $0`
Version="1.0"
Synopsis="An N_section must end on the line containing ')'"
ExitStatus="1"
Counters="ERRORS: 2 WARNINGS: 3"
ExtraFiles="model_example.jpg secta.s4p sectb.s4p sectc.s4p"
GNUCheck="Yes"

Description=`cat <<'EOF'
This test extends an N_section to a line after the closing ')'

Errors are expected.
EOF`

Output=`cat <<'EOF'
IBIS ICM Parser, version 1.0.0
ERROR (Line 61/Col 35) parse error, unexpected END_OF_LINE, expecting Mult_EQ or Len_EQ
ERROR (Line 62/Col 35) parse error, unexpected Mult_EQ
WARNING (Line 59/Col 3) Node Map 'MyModelNodeMapA' node 'A1' is not connected to any N_section in Model 'MyModelExample2'.
WARNING (Line 59/Col 3) Node Map 'MyModelNodeMapA' node 'A2' is not connected to any N_section in Model 'MyModelExample2'.
WARNING (Line 122/Col 1) Section 'SectA_rlgc' was defined but not used.
Finished. ERRORS: 2 WARNINGS: 3
EOF`

ICM=`cat <<'EOF'

|
|**********************************************************************
[Begin Header]
[ICM Ver]             1.0
[File Name]           test_157.icm
[File Rev]            0.1
[Date]                March 17, 2003
[Source]              Created by Michael Mirmak, Intel Corp.
[Notes]               This file shows how the ICM specification, at
                      level 1.0a, would implement an S-parameter 
                      description of an interconnect.
[Disclaimer]          No license, express or implied, by estoppel or 
                      otherwise, to any intellectual property rights is 
                      granted by this document. 
[Copyright]           None - public domain
[Support]             http://www.vhdl.org/pub/ibis/
[Redistribution]      Yes    
[Redistribution Text] Stick your favorite T's and C' here! 
[End Header]
|**********************************************************************
|
[Comment Char] |_char
|
|**********************************************************************
[Begin ICM Family]        S_parameter_example
[Manufacturer]            None
[ICM Family Description]  
A very crude s-parameter example for parsing and analysis.
|**********************************************************************
[ICM Model List] 
|  Name             Mating   Min_Slew_Time           Image
MyModelExample1     Mated       100ps            model_example.jpg
MyModelExample2     Mated       100ps            model_example.jpg
|
|          SectA       SectB       SectC   
| Port1 >---------< >---------< >---------<  Port2
|
|**********************************************************************
[Begin ICM Model] MyModelExample1
ICM_model_type S-parameter
|
[Nodal Path Description]
  Model_nodemap MyModelNodeMapA
  N_section ( A1  A2    
                        AB1 AB2 ) Mult=1 SectA
  N_section ( AB1 AB2   
                        BC1 BC2 ) Mult=1 SectB
  N_section ( BC1 BC2   
                        C1  C2  ) Mult=1 SectC
  Model_nodemap MyModelNodeMapC
|
[End ICM Model]
|
[Begin ICM Model] MyModelExample2
ICM_model_type SLM_general
SGR 1:1
[Nodal Path Description]
  Model_nodemap MyModelNodeMapA
  N_section ( A1  A2    
                        AB1 AB2 ) 
                                  Mult=1 SectA_rlgc
  N_section ( AB1 AB2   BC1 BC2 ) Mult=1 SectB_rlgc
  N_section ( BC1 BC2   C1  C2  ) Mult=1 SectC_rlgc
  Model_nodemap MyModelNodeMapC
|
[End ICM Model]
|
|**********************************************************************
[ICM Node Map] MyModelNodeMapA
|Pin Node Name
 1   A1   AD12_IN
 2   A2   AD15_IN

[ICM Node Map] MyModelNodeMapC
|Pin Node Name
 1   C1   AD12_OUT
 2   C2   AD15_OUT

[End ICM Family]
|
|**********************************************************************
[Begin ICM Section] SectA
[Derivation Method] Lumped
[ICM S-parameter]
File_name secta.s4p
Port_assignment
| Port Node
1   A1
2   A2
3   AB1
4   AB2
[End ICM Section] SectA

|**********************************************************************
[Begin ICM Section] SectB
[Derivation Method] Lumped
[ICM S-parameter]
File_name sectb.s4p
Port_assignment
| Port NOde
1   AB1
2   AB2
3   BC1
4   BC2
[End ICM Section] SectB

|**********************************************************************
[Begin ICM Section] SectC
[Derivation Method] Lumped
[ICM S-parameter]
File_name sectc.s4p
Port_assignment
| Port Node
1   BC1
2   BC2
3   C1
4   C2
[End ICM Section] SectC

|**********************************************************************
[Begin ICM Section] SectA_rlgc
[Derivation Method] Lumped
[Resistance Matrix] Diagonal_matrix
1.0mohm
1.0e-3
[Inductance Matrix] Diagonal_matrix
4.0nh
4.0e-9
[Capacitance Matrix] Diagonal_matrix
2.0pf
2.0e-12
[End ICM Section] SectA_rlgc

|**********************************************************************
[Begin ICM Section] SectB_rlgc
[Derivation Method] Lumped
[Resistance Matrix] Diagonal_matrix
1.0mohm
1.0e-3
[Inductance Matrix] Diagonal_matrix
4.0nh
4.0e-9
[Capacitance Matrix] Diagonal_matrix
2.0pf
2.0e-12
[End ICM Section] SectB_rlgc

|**********************************************************************
[Begin ICM Section] SectC_rlgc
[Derivation Method] Lumped
[Resistance Matrix] Diagonal_matrix
1.0mohm
1.0e-3
[Inductance Matrix] Diagonal_matrix
4.0nh
4.0e-9
[Capacitance Matrix] Diagonal_matrix
2.0pf
2.0e-12
[End ICM Section] SectC_rlgc

|**********************************************************************
[End]
|**********************************************************************
EOF`

if [ -z "${srcdir}" ]
then
    srcdir="."
fi

export srcdir Test Version Synopsis ExitStatus Counters ExtraFiles GNUCheck Description Output ICM

exec ${srcdir}/run_test "$@"
