(ctx context.Context, t *testctx.T)
| 1788 | } |
| 1789 | |
| 1790 | func (PythonSuite) TestNameConflicts(ctx context.Context, t *testctx.T) { |
| 1791 | c := connect(ctx, t) |
| 1792 | |
| 1793 | modGen := pythonModInit(t, c, ` |
| 1794 | from dagger import field, function, object_type |
| 1795 | |
| 1796 | @object_type |
| 1797 | class Test: |
| 1798 | from_: str = field(default="") |
| 1799 | |
| 1800 | @function |
| 1801 | def pass_(self, import_: str = "") -> str: |
| 1802 | return import_ |
| 1803 | `) |
| 1804 | |
| 1805 | out, err := modGen.With(daggerCall("--from=foo", "from")).Stdout(ctx) |
| 1806 | require.NoError(t, err) |
| 1807 | require.Equal(t, "foo", out) |
| 1808 | |
| 1809 | out, err = modGen.With(daggerCall("pass", "--import=bar")).Stdout(ctx) |
| 1810 | require.NoError(t, err) |
| 1811 | require.Equal(t, "bar", out) |
| 1812 | } |
| 1813 | |
| 1814 | func (PythonSuite) TestNameOverrides(ctx context.Context, t *testctx.T) { |
| 1815 | c := connect(ctx, t) |
nothing calls this directly
no test coverage detected